package impl;

import service.Breakfast;

/**
 * 服务员负责命令的调用invoke
 * 调用相应的命令执行者去执行
 */
public class Waiter {
    private Breakfast breakfast;

    public Breakfast getBreakfast() {
        return breakfast;
    }

    public void setBreakfast(Breakfast breakfast) {
        this.breakfast = breakfast;
    }

    public void invoke() {
        System.out.println("服务员调用命令...");
        breakfast.cooking();
    }
}
